<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Doxygen: pcl::features::ISMVoteList&lt; PointT &gt; 模板类 参考</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Doxygen
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'搜索','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','搜索');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classpcl_1_1features_1_1_i_s_m_vote_list.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public 成员函数</a> &#124;
<a href="#pro-methods">Protected 成员函数</a> &#124;
<a href="#pro-attribs">Protected 属性</a> &#124;
<a href="classpcl_1_1features_1_1_i_s_m_vote_list-members.html">所有成员列表</a>  </div>
  <div class="headertitle">
<div class="title">pcl::features::ISMVoteList&lt; PointT &gt; 模板类 参考</div>  </div>
</div><!--header-->
<div class="contents">

<p>This class is used for storing, analyzing and manipulating votes obtained from ISM algorithm.  
 <a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#details">更多...</a></p>

<p><code>#include &lt;<a class="el" href="implicit__shape__model_8h_source.html">implicit_shape_model.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public 成员函数</h2></td></tr>
<tr class="memitem:aeefba7e2950f49b5923e4d76962c6f10"><td class="memItemLeft" align="right" valign="top"><a id="aeefba7e2950f49b5923e4d76962c6f10"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aeefba7e2950f49b5923e4d76962c6f10">ISMVoteList</a> ()</td></tr>
<tr class="memdesc:aeefba7e2950f49b5923e4d76962c6f10"><td class="mdescLeft">&#160;</td><td class="mdescRight">Empty constructor with member variables initialization. <br /></td></tr>
<tr class="separator:aeefba7e2950f49b5923e4d76962c6f10"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aecd4e03778ec4df656e9a1b410ae905c"><td class="memItemLeft" align="right" valign="top"><a id="aecd4e03778ec4df656e9a1b410ae905c"></a>
virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aecd4e03778ec4df656e9a1b410ae905c">~ISMVoteList</a> ()</td></tr>
<tr class="memdesc:aecd4e03778ec4df656e9a1b410ae905c"><td class="mdescLeft">&#160;</td><td class="mdescRight">virtual descriptor. <br /></td></tr>
<tr class="separator:aecd4e03778ec4df656e9a1b410ae905c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a224bb7843bc1493b510b53884ac1b71c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a224bb7843bc1493b510b53884ac1b71c">addVote</a> (<a class="el" href="structpcl_1_1_interest_point.html">pcl::InterestPoint</a> &amp;in_vote, const <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &amp;vote_origin, int in_class)</td></tr>
<tr class="memdesc:a224bb7843bc1493b510b53884ac1b71c"><td class="mdescLeft">&#160;</td><td class="mdescRight">This method simply adds another vote to the list.  <a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a224bb7843bc1493b510b53884ac1b71c">更多...</a><br /></td></tr>
<tr class="separator:a224bb7843bc1493b510b53884ac1b71c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8af69407ed99f978fc73b245d2540c6b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classpcl_1_1_point_cloud.html">pcl::PointCloud</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b.html">pcl::PointXYZRGB</a> &gt;::Ptr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a8af69407ed99f978fc73b245d2540c6b">getColoredCloud</a> (typename <a class="el" href="classpcl_1_1_point_cloud.html">pcl::PointCloud</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &gt;::Ptr cloud=0)</td></tr>
<tr class="memdesc:a8af69407ed99f978fc73b245d2540c6b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the colored cloud that consists of votes for center (blue points) and initial point cloud (if it was passed).  <a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a8af69407ed99f978fc73b245d2540c6b">更多...</a><br /></td></tr>
<tr class="separator:a8af69407ed99f978fc73b245d2540c6b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2b1a5eb2c233baa767d1eb8becae92c4"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a2b1a5eb2c233baa767d1eb8becae92c4">findStrongestPeaks</a> (std::vector&lt; <a class="el" href="structpcl_1_1_i_s_m_peak.html">ISMPeak</a>, Eigen::aligned_allocator&lt; <a class="el" href="structpcl_1_1_i_s_m_peak.html">ISMPeak</a> &gt; &gt; &amp;out_peaks, int in_class_id, double in_non_maxima_radius, double in_sigma)</td></tr>
<tr class="memdesc:a2b1a5eb2c233baa767d1eb8becae92c4"><td class="mdescLeft">&#160;</td><td class="mdescRight">This method finds the strongest peaks (points were density has most higher values). It is based on the non maxima supression principles.  <a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a2b1a5eb2c233baa767d1eb8becae92c4">更多...</a><br /></td></tr>
<tr class="separator:a2b1a5eb2c233baa767d1eb8becae92c4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac284edd6499950c3eafe533608e5b132"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ac284edd6499950c3eafe533608e5b132">getDensityAtPoint</a> (const <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &amp;point, double sigma_dist)</td></tr>
<tr class="memdesc:ac284edd6499950c3eafe533608e5b132"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the density at the specified point.  <a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ac284edd6499950c3eafe533608e5b132">更多...</a><br /></td></tr>
<tr class="separator:ac284edd6499950c3eafe533608e5b132"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab3c9ca4a2308c959ac5a0009be35f7a8"><td class="memItemLeft" align="right" valign="top"><a id="ab3c9ca4a2308c959ac5a0009be35f7a8"></a>
unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ab3c9ca4a2308c959ac5a0009be35f7a8">getNumberOfVotes</a> ()</td></tr>
<tr class="memdesc:ab3c9ca4a2308c959ac5a0009be35f7a8"><td class="mdescLeft">&#160;</td><td class="mdescRight">This method simply returns the number of votes. <br /></td></tr>
<tr class="separator:ab3c9ca4a2308c959ac5a0009be35f7a8"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-methods"></a>
Protected 成员函数</h2></td></tr>
<tr class="memitem:ab49403392d4d4a0384c2a1c76d097b8b"><td class="memItemLeft" align="right" valign="top"><a id="ab49403392d4d4a0384c2a1c76d097b8b"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ab49403392d4d4a0384c2a1c76d097b8b">validateTree</a> ()</td></tr>
<tr class="memdesc:ab49403392d4d4a0384c2a1c76d097b8b"><td class="mdescLeft">&#160;</td><td class="mdescRight">this method is simply setting up the search tree. <br /></td></tr>
<tr class="separator:ab49403392d4d4a0384c2a1c76d097b8b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a013f4e13bb8f1905de0afe8c76d78c14"><td class="memItemLeft" align="right" valign="top"><a id="a013f4e13bb8f1905de0afe8c76d78c14"></a>
Eigen::Vector3f&#160;</td><td class="memItemRight" valign="bottom"><b>shiftMean</b> (const Eigen::Vector3f &amp;snapPt, const double in_dSigmaDist)</td></tr>
<tr class="separator:a013f4e13bb8f1905de0afe8c76d78c14"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-attribs"></a>
Protected 属性</h2></td></tr>
<tr class="memitem:aa5218ed40f67da06286a35f22cf9d9b3"><td class="memItemLeft" align="right" valign="top"><a id="aa5218ed40f67da06286a35f22cf9d9b3"></a>
<a class="el" href="classpcl_1_1_point_cloud.html">pcl::PointCloud</a>&lt; <a class="el" href="structpcl_1_1_interest_point.html">pcl::InterestPoint</a> &gt;::Ptr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a></td></tr>
<tr class="memdesc:aa5218ed40f67da06286a35f22cf9d9b3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stores all votes. <br /></td></tr>
<tr class="separator:aa5218ed40f67da06286a35f22cf9d9b3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1d5d255232e45072f9be2d61da82ca90"><td class="memItemLeft" align="right" valign="top"><a id="a1d5d255232e45072f9be2d61da82ca90"></a>
bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a1d5d255232e45072f9be2d61da82ca90">tree_is_valid_</a></td></tr>
<tr class="memdesc:a1d5d255232e45072f9be2d61da82ca90"><td class="mdescLeft">&#160;</td><td class="mdescRight">Signalizes if the tree is valid. <br /></td></tr>
<tr class="separator:a1d5d255232e45072f9be2d61da82ca90"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a70eb357949f48386d468e6abe140e23d"><td class="memItemLeft" align="right" valign="top"><a id="a70eb357949f48386d468e6abe140e23d"></a>
<a class="el" href="classpcl_1_1_point_cloud.html">pcl::PointCloud</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &gt;::Ptr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a70eb357949f48386d468e6abe140e23d">votes_origins_</a></td></tr>
<tr class="memdesc:a70eb357949f48386d468e6abe140e23d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stores the origins of the votes. <br /></td></tr>
<tr class="separator:a70eb357949f48386d468e6abe140e23d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5ffef33d1b4f225fbd38833d55c18cb1"><td class="memItemLeft" align="right" valign="top"><a id="a5ffef33d1b4f225fbd38833d55c18cb1"></a>
std::vector&lt; int &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a5ffef33d1b4f225fbd38833d55c18cb1">votes_class_</a></td></tr>
<tr class="memdesc:a5ffef33d1b4f225fbd38833d55c18cb1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stores classes for which every single vote was cast. <br /></td></tr>
<tr class="separator:a5ffef33d1b4f225fbd38833d55c18cb1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a53a6809b8f7069b2f5a0a4f601f0059f"><td class="memItemLeft" align="right" valign="top"><a id="a53a6809b8f7069b2f5a0a4f601f0059f"></a>
<a class="el" href="classpcl_1_1_kd_tree_f_l_a_n_n.html">pcl::KdTreeFLANN</a>&lt; <a class="el" href="structpcl_1_1_interest_point.html">pcl::InterestPoint</a> &gt;::Ptr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a53a6809b8f7069b2f5a0a4f601f0059f">tree_</a></td></tr>
<tr class="memdesc:a53a6809b8f7069b2f5a0a4f601f0059f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stores the search tree. <br /></td></tr>
<tr class="separator:a53a6809b8f7069b2f5a0a4f601f0059f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0ddbc7ee40f769a5c94f755197fefccb"><td class="memItemLeft" align="right" valign="top"><a id="a0ddbc7ee40f769a5c94f755197fefccb"></a>
std::vector&lt; int &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a0ddbc7ee40f769a5c94f755197fefccb">k_ind_</a></td></tr>
<tr class="memdesc:a0ddbc7ee40f769a5c94f755197fefccb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stores neighbours indices. <br /></td></tr>
<tr class="separator:a0ddbc7ee40f769a5c94f755197fefccb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3ddce2a6ca230560e4aa94d84816acb2"><td class="memItemLeft" align="right" valign="top"><a id="a3ddce2a6ca230560e4aa94d84816acb2"></a>
std::vector&lt; float &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a3ddce2a6ca230560e4aa94d84816acb2">k_sqr_dist_</a></td></tr>
<tr class="memdesc:a3ddce2a6ca230560e4aa94d84816acb2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stores square distances to the corresponding neighbours. <br /></td></tr>
<tr class="separator:a3ddce2a6ca230560e4aa94d84816acb2"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">详细描述</h2>
<div class="textblock"><h3>template&lt;typename PointT&gt;<br />
class pcl::features::ISMVoteList&lt; PointT &gt;</h3>

<p>This class is used for storing, analyzing and manipulating votes obtained from ISM algorithm. </p>
</div><h2 class="groupheader">成员函数说明</h2>
<a id="a224bb7843bc1493b510b53884ac1b71c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a224bb7843bc1493b510b53884ac1b71c">&#9670;&nbsp;</a></span>addVote()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename PointT &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html">pcl::features::ISMVoteList</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &gt;::addVote </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structpcl_1_1_interest_point.html">pcl::InterestPoint</a> &amp;&#160;</td>
          <td class="paramname"><em>in_vote</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &amp;&#160;</td>
          <td class="paramname"><em>vote_origin</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>in_class</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This method simply adds another vote to the list. </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">in_vote</td><td>vote to add </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">vote_origin</td><td>origin of the added vote </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">in_class</td><td>class for which this vote is cast </td></tr>
  </table>
  </dd>
</dl>
<div class="fragment"><div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;{</div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;  <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a1d5d255232e45072f9be2d61da82ca90">tree_is_valid_</a> = <span class="keyword">false</span>;</div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;  <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.insert (<a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.end (), vote);<span class="comment">// TODO: adjust height and width</span></div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160; </div>
<div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160;  <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a70eb357949f48386d468e6abe140e23d">votes_origins_</a>-&gt;points.push_back (vote_origin);</div>
<div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160;  <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a5ffef33d1b4f225fbd38833d55c18cb1">votes_class_</a>.push_back (votes_class);</div>
<div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;}</div>
<div class="ttc" id="aclasspcl_1_1_point_cloud_html_af16a62638198313b9c093127c492c884"><div class="ttname"><a href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">pcl::PointCloud::points</a></div><div class="ttdeci">std::vector&lt; PointT, Eigen::aligned_allocator&lt; PointT &gt; &gt; points</div><div class="ttdoc">The point data.</div><div class="ttdef"><b>Definition:</b> point_cloud.h:410</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_a1d5d255232e45072f9be2d61da82ca90"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a1d5d255232e45072f9be2d61da82ca90">pcl::features::ISMVoteList::tree_is_valid_</a></div><div class="ttdeci">bool tree_is_valid_</div><div class="ttdoc">Signalizes if the tree is valid.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:138</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_a5ffef33d1b4f225fbd38833d55c18cb1"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a5ffef33d1b4f225fbd38833d55c18cb1">pcl::features::ISMVoteList::votes_class_</a></div><div class="ttdeci">std::vector&lt; int &gt; votes_class_</div><div class="ttdoc">Stores classes for which every single vote was cast.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:144</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_a70eb357949f48386d468e6abe140e23d"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a70eb357949f48386d468e6abe140e23d">pcl::features::ISMVoteList::votes_origins_</a></div><div class="ttdeci">pcl::PointCloud&lt; PointT &gt;::Ptr votes_origins_</div><div class="ttdoc">Stores the origins of the votes.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:141</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_aa5218ed40f67da06286a35f22cf9d9b3"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">pcl::features::ISMVoteList::votes_</a></div><div class="ttdeci">pcl::PointCloud&lt; pcl::InterestPoint &gt;::Ptr votes_</div><div class="ttdoc">Stores all votes.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:135</div></div>
</div><!-- fragment -->
</div>
</div>
<a id="a2b1a5eb2c233baa767d1eb8becae92c4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2b1a5eb2c233baa767d1eb8becae92c4">&#9670;&nbsp;</a></span>findStrongestPeaks()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename PointT &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html">pcl::features::ISMVoteList</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &gt;::findStrongestPeaks </td>
          <td>(</td>
          <td class="paramtype">std::vector&lt; <a class="el" href="structpcl_1_1_i_s_m_peak.html">ISMPeak</a>, Eigen::aligned_allocator&lt; <a class="el" href="structpcl_1_1_i_s_m_peak.html">ISMPeak</a> &gt; &gt; &amp;&#160;</td>
          <td class="paramname"><em>out_peaks</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>in_class_id</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>in_non_maxima_radius</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>in_sigma</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This method finds the strongest peaks (points were density has most higher values). It is based on the non maxima supression principles. </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">out_peaks</td><td>it will contain the strongest peaks </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">in_class_id</td><td>class of interest for which peaks are evaluated </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">in_non_maxima_radius</td><td>non maxima supression radius. The shapes radius is recommended for this value. </td></tr>
    <tr><td class="paramdir"></td><td class="paramname">in_sigma</td><td></td></tr>
  </table>
  </dd>
</dl>
<div class="fragment"><div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;{</div>
<div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;  <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ab49403392d4d4a0384c2a1c76d097b8b">validateTree</a> ();</div>
<div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160; </div>
<div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;  <span class="keyword">const</span> <span class="keywordtype">size_t</span> n_vote_classes = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a5ffef33d1b4f225fbd38833d55c18cb1">votes_class_</a>.size ();</div>
<div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160;  <span class="keywordflow">if</span> (n_vote_classes == 0)</div>
<div class="line"><a name="l00134"></a><span class="lineno">  134</span>&#160;    <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00135"></a><span class="lineno">  135</span>&#160;  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i &lt; n_vote_classes ; i++)</div>
<div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160;    assert ( <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a5ffef33d1b4f225fbd38833d55c18cb1">votes_class_</a>[i] == in_class_id );</div>
<div class="line"><a name="l00137"></a><span class="lineno">  137</span>&#160; </div>
<div class="line"><a name="l00138"></a><span class="lineno">  138</span>&#160;  <span class="comment">// heuristic: start from NUM_INIT_PTS different locations selected uniformly</span></div>
<div class="line"><a name="l00139"></a><span class="lineno">  139</span>&#160;  <span class="comment">// on the votes. Intuitively, it is likely to get a good location in dense regions.</span></div>
<div class="line"><a name="l00140"></a><span class="lineno">  140</span>&#160;  <span class="keyword">const</span> <span class="keywordtype">int</span> NUM_INIT_PTS = 100;</div>
<div class="line"><a name="l00141"></a><span class="lineno">  141</span>&#160;  <span class="keywordtype">double</span> SIGMA_DIST = in_sigma;<span class="comment">// rule of thumb: 10% of the object radius</span></div>
<div class="line"><a name="l00142"></a><span class="lineno">  142</span>&#160;  <span class="keyword">const</span> <span class="keywordtype">double</span> FINAL_EPS = SIGMA_DIST / 100;<span class="comment">// another heuristic</span></div>
<div class="line"><a name="l00143"></a><span class="lineno">  143</span>&#160; </div>
<div class="line"><a name="l00144"></a><span class="lineno">  144</span>&#160;  std::vector&lt;Eigen::Vector3f, Eigen::aligned_allocator&lt;Eigen::Vector3f&gt; &gt; peaks (NUM_INIT_PTS);</div>
<div class="line"><a name="l00145"></a><span class="lineno">  145</span>&#160;  std::vector&lt;double&gt; peak_densities (NUM_INIT_PTS);</div>
<div class="line"><a name="l00146"></a><span class="lineno">  146</span>&#160;  <span class="keywordtype">double</span> max_density = -1.0;</div>
<div class="line"><a name="l00147"></a><span class="lineno">  147</span>&#160;  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i &lt; NUM_INIT_PTS; i++)</div>
<div class="line"><a name="l00148"></a><span class="lineno">  148</span>&#160;  {</div>
<div class="line"><a name="l00149"></a><span class="lineno">  149</span>&#160;    Eigen::Vector3f old_center;</div>
<div class="line"><a name="l00150"></a><span class="lineno">  150</span>&#160;    Eigen::Vector3f curr_center;</div>
<div class="line"><a name="l00151"></a><span class="lineno">  151</span>&#160;    curr_center (0) = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>[<a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.size () * i / NUM_INIT_PTS].x;</div>
<div class="line"><a name="l00152"></a><span class="lineno">  152</span>&#160;    curr_center (1) = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>[<a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.size () * i / NUM_INIT_PTS].y;</div>
<div class="line"><a name="l00153"></a><span class="lineno">  153</span>&#160;    curr_center (2) = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>[<a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.size () * i / NUM_INIT_PTS].z;</div>
<div class="line"><a name="l00154"></a><span class="lineno">  154</span>&#160; </div>
<div class="line"><a name="l00155"></a><span class="lineno">  155</span>&#160;    <span class="keywordflow">do</span></div>
<div class="line"><a name="l00156"></a><span class="lineno">  156</span>&#160;    {</div>
<div class="line"><a name="l00157"></a><span class="lineno">  157</span>&#160;      old_center = curr_center;</div>
<div class="line"><a name="l00158"></a><span class="lineno">  158</span>&#160;      curr_center = shiftMean (old_center, SIGMA_DIST);</div>
<div class="line"><a name="l00159"></a><span class="lineno">  159</span>&#160;    } <span class="keywordflow">while</span> ((old_center - curr_center).norm () &gt; FINAL_EPS);</div>
<div class="line"><a name="l00160"></a><span class="lineno">  160</span>&#160; </div>
<div class="line"><a name="l00161"></a><span class="lineno">  161</span>&#160;    <a class="code" href="structpcl_1_1_point_x_y_z.html">pcl::PointXYZ</a> point;</div>
<div class="line"><a name="l00162"></a><span class="lineno">  162</span>&#160;    point.x = curr_center (0);</div>
<div class="line"><a name="l00163"></a><span class="lineno">  163</span>&#160;    point.y = curr_center (1);</div>
<div class="line"><a name="l00164"></a><span class="lineno">  164</span>&#160;    point.z = curr_center (2);</div>
<div class="line"><a name="l00165"></a><span class="lineno">  165</span>&#160;    <span class="keywordtype">double</span> curr_density = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ac284edd6499950c3eafe533608e5b132">getDensityAtPoint</a> (point, SIGMA_DIST);</div>
<div class="line"><a name="l00166"></a><span class="lineno">  166</span>&#160;    assert (curr_density &gt;= 0.0);</div>
<div class="line"><a name="l00167"></a><span class="lineno">  167</span>&#160; </div>
<div class="line"><a name="l00168"></a><span class="lineno">  168</span>&#160;    peaks[i] = curr_center;</div>
<div class="line"><a name="l00169"></a><span class="lineno">  169</span>&#160;    peak_densities[i] = curr_density;</div>
<div class="line"><a name="l00170"></a><span class="lineno">  170</span>&#160; </div>
<div class="line"><a name="l00171"></a><span class="lineno">  171</span>&#160;    <span class="keywordflow">if</span> ( max_density &lt; curr_density )</div>
<div class="line"><a name="l00172"></a><span class="lineno">  172</span>&#160;      max_density = curr_density;</div>
<div class="line"><a name="l00173"></a><span class="lineno">  173</span>&#160;  }</div>
<div class="line"><a name="l00174"></a><span class="lineno">  174</span>&#160; </div>
<div class="line"><a name="l00175"></a><span class="lineno">  175</span>&#160;  <span class="comment">//extract peaks</span></div>
<div class="line"><a name="l00176"></a><span class="lineno">  176</span>&#160;  std::vector&lt;bool&gt; peak_flag (NUM_INIT_PTS, <span class="keyword">true</span>);</div>
<div class="line"><a name="l00177"></a><span class="lineno">  177</span>&#160;  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i_peak = 0; i_peak &lt; NUM_INIT_PTS; i_peak++)</div>
<div class="line"><a name="l00178"></a><span class="lineno">  178</span>&#160;  {</div>
<div class="line"><a name="l00179"></a><span class="lineno">  179</span>&#160;    <span class="comment">// find best peak with taking into consideration peak flags</span></div>
<div class="line"><a name="l00180"></a><span class="lineno">  180</span>&#160;    <span class="keywordtype">double</span> best_density = -1.0;</div>
<div class="line"><a name="l00181"></a><span class="lineno">  181</span>&#160;    Eigen::Vector3f strongest_peak;</div>
<div class="line"><a name="l00182"></a><span class="lineno">  182</span>&#160;    <span class="keywordtype">int</span> best_peak_ind (-1);</div>
<div class="line"><a name="l00183"></a><span class="lineno">  183</span>&#160;    <span class="keywordtype">int</span> peak_counter (0);</div>
<div class="line"><a name="l00184"></a><span class="lineno">  184</span>&#160;    <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i &lt; NUM_INIT_PTS; i++)</div>
<div class="line"><a name="l00185"></a><span class="lineno">  185</span>&#160;    {</div>
<div class="line"><a name="l00186"></a><span class="lineno">  186</span>&#160;      <span class="keywordflow">if</span> ( !peak_flag[i] )</div>
<div class="line"><a name="l00187"></a><span class="lineno">  187</span>&#160;        <span class="keywordflow">continue</span>;</div>
<div class="line"><a name="l00188"></a><span class="lineno">  188</span>&#160; </div>
<div class="line"><a name="l00189"></a><span class="lineno">  189</span>&#160;      <span class="keywordflow">if</span> ( peak_densities[i] &gt; best_density)</div>
<div class="line"><a name="l00190"></a><span class="lineno">  190</span>&#160;      {</div>
<div class="line"><a name="l00191"></a><span class="lineno">  191</span>&#160;        best_density = peak_densities[i];</div>
<div class="line"><a name="l00192"></a><span class="lineno">  192</span>&#160;        strongest_peak = peaks[i];</div>
<div class="line"><a name="l00193"></a><span class="lineno">  193</span>&#160;        best_peak_ind = i;</div>
<div class="line"><a name="l00194"></a><span class="lineno">  194</span>&#160;      }</div>
<div class="line"><a name="l00195"></a><span class="lineno">  195</span>&#160;      ++peak_counter;</div>
<div class="line"><a name="l00196"></a><span class="lineno">  196</span>&#160;    }</div>
<div class="line"><a name="l00197"></a><span class="lineno">  197</span>&#160; </div>
<div class="line"><a name="l00198"></a><span class="lineno">  198</span>&#160;    <span class="keywordflow">if</span>( peak_counter == 0 )</div>
<div class="line"><a name="l00199"></a><span class="lineno">  199</span>&#160;      <span class="keywordflow">break</span>;<span class="comment">// no peaks</span></div>
<div class="line"><a name="l00200"></a><span class="lineno">  200</span>&#160; </div>
<div class="line"><a name="l00201"></a><span class="lineno">  201</span>&#160;    <a class="code" href="structpcl_1_1_i_s_m_peak.html">pcl::ISMPeak</a> peak;</div>
<div class="line"><a name="l00202"></a><span class="lineno">  202</span>&#160;    peak.x = strongest_peak(0);</div>
<div class="line"><a name="l00203"></a><span class="lineno">  203</span>&#160;    peak.y = strongest_peak(1);</div>
<div class="line"><a name="l00204"></a><span class="lineno">  204</span>&#160;    peak.z = strongest_peak(2);</div>
<div class="line"><a name="l00205"></a><span class="lineno">  205</span>&#160;    peak.<a class="code" href="structpcl_1_1_i_s_m_peak.html#ab396d6f73ad331b39585bc37f481230b">density</a> = best_density;</div>
<div class="line"><a name="l00206"></a><span class="lineno">  206</span>&#160;    peak.<a class="code" href="structpcl_1_1_i_s_m_peak.html#ab5ade3a0df41fe9043dd86751a17dbf9">class_id</a> = in_class_id;</div>
<div class="line"><a name="l00207"></a><span class="lineno">  207</span>&#160;    out_peaks.push_back ( peak );</div>
<div class="line"><a name="l00208"></a><span class="lineno">  208</span>&#160; </div>
<div class="line"><a name="l00209"></a><span class="lineno">  209</span>&#160;    <span class="comment">// mark best peaks and all its neighbors</span></div>
<div class="line"><a name="l00210"></a><span class="lineno">  210</span>&#160;    peak_flag[best_peak_ind] = <span class="keyword">false</span>;</div>
<div class="line"><a name="l00211"></a><span class="lineno">  211</span>&#160;    <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i &lt; NUM_INIT_PTS; i++)</div>
<div class="line"><a name="l00212"></a><span class="lineno">  212</span>&#160;    {</div>
<div class="line"><a name="l00213"></a><span class="lineno">  213</span>&#160;      <span class="comment">// compute distance between best peak and all unmarked peaks</span></div>
<div class="line"><a name="l00214"></a><span class="lineno">  214</span>&#160;      <span class="keywordflow">if</span> ( !peak_flag[i] )</div>
<div class="line"><a name="l00215"></a><span class="lineno">  215</span>&#160;        <span class="keywordflow">continue</span>;</div>
<div class="line"><a name="l00216"></a><span class="lineno">  216</span>&#160; </div>
<div class="line"><a name="l00217"></a><span class="lineno">  217</span>&#160;      <span class="keywordtype">double</span> dist = (strongest_peak - peaks[i]).norm ();</div>
<div class="line"><a name="l00218"></a><span class="lineno">  218</span>&#160;      <span class="keywordflow">if</span> ( dist &lt; in_non_maxima_radius )</div>
<div class="line"><a name="l00219"></a><span class="lineno">  219</span>&#160;        peak_flag[i] = <span class="keyword">false</span>;</div>
<div class="line"><a name="l00220"></a><span class="lineno">  220</span>&#160;    }</div>
<div class="line"><a name="l00221"></a><span class="lineno">  221</span>&#160;  }</div>
<div class="line"><a name="l00222"></a><span class="lineno">  222</span>&#160;}</div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_ab49403392d4d4a0384c2a1c76d097b8b"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ab49403392d4d4a0384c2a1c76d097b8b">pcl::features::ISMVoteList::validateTree</a></div><div class="ttdeci">void validateTree()</div><div class="ttdoc">this method is simply setting up the search tree.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.hpp:226</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_ac284edd6499950c3eafe533608e5b132"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ac284edd6499950c3eafe533608e5b132">pcl::features::ISMVoteList::getDensityAtPoint</a></div><div class="ttdeci">double getDensityAtPoint(const PointT &amp;point, double sigma_dist)</div><div class="ttdoc">Returns the density at the specified point.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.hpp:268</div></div>
<div class="ttc" id="astructpcl_1_1_i_s_m_peak_html"><div class="ttname"><a href="structpcl_1_1_i_s_m_peak.html">pcl::ISMPeak</a></div><div class="ttdoc">This struct is used for storing peak.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:59</div></div>
<div class="ttc" id="astructpcl_1_1_i_s_m_peak_html_ab396d6f73ad331b39585bc37f481230b"><div class="ttname"><a href="structpcl_1_1_i_s_m_peak.html#ab396d6f73ad331b39585bc37f481230b">pcl::ISMPeak::density</a></div><div class="ttdeci">double density</div><div class="ttdoc">Density of this peak.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:64</div></div>
<div class="ttc" id="astructpcl_1_1_i_s_m_peak_html_ab5ade3a0df41fe9043dd86751a17dbf9"><div class="ttname"><a href="structpcl_1_1_i_s_m_peak.html#ab5ade3a0df41fe9043dd86751a17dbf9">pcl::ISMPeak::class_id</a></div><div class="ttdeci">int class_id</div><div class="ttdoc">Determines which class this peak belongs.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:67</div></div>
<div class="ttc" id="astructpcl_1_1_point_x_y_z_html"><div class="ttname"><a href="structpcl_1_1_point_x_y_z.html">pcl::PointXYZ</a></div><div class="ttdoc">A point structure representing Euclidean xyz coordinates. (SSE friendly)</div><div class="ttdef"><b>Definition:</b> point_types.hpp:282</div></div>
</div><!-- fragment -->
</div>
</div>
<a id="a8af69407ed99f978fc73b245d2540c6b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8af69407ed99f978fc73b245d2540c6b">&#9670;&nbsp;</a></span>getColoredCloud()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename PointT &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classpcl_1_1_point_cloud.html">pcl::PointCloud</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b.html">pcl::PointXYZRGB</a> &gt;::Ptr <a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html">pcl::features::ISMVoteList</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &gt;::getColoredCloud </td>
          <td>(</td>
          <td class="paramtype">typename <a class="el" href="classpcl_1_1_point_cloud.html">pcl::PointCloud</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &gt;::Ptr&#160;</td>
          <td class="paramname"><em>cloud</em> = <code>0</code></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns the colored cloud that consists of votes for center (blue points) and initial point cloud (if it was passed). </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">cloud</td><td>cloud that needs to be merged with votes for visualizing. </td></tr>
  </table>
  </dd>
</dl>
<div class="fragment"><div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;{</div>
<div class="line"><a name="l00087"></a><span class="lineno">   87</span>&#160;  <a class="code" href="structpcl_1_1_point_x_y_z_r_g_b.html">pcl::PointXYZRGB</a> point;</div>
<div class="line"><a name="l00088"></a><span class="lineno">   88</span>&#160;  pcl::PointCloud&lt;pcl::PointXYZRGB&gt;::Ptr colored_cloud = (<span class="keyword">new</span> <a class="code" href="classpcl_1_1_point_cloud.html">pcl::PointCloud&lt;pcl::PointXYZRGB&gt;</a>)-&gt;makeShared ();</div>
<div class="line"><a name="l00089"></a><span class="lineno">   89</span>&#160;  colored_cloud-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#a4f34b45220c57f96607513ffad0d9582">height</a> = 0;</div>
<div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;  colored_cloud-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#a2185a6453f8ad905d7bdf7b45754a160">width</a> = 1;</div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160; </div>
<div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;  <span class="keywordflow">if</span> (cloud != 0)</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;  {</div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160;    colored_cloud-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#a4f34b45220c57f96607513ffad0d9582">height</a> += <span class="keyword">static_cast&lt;</span>uint32_t<span class="keyword">&gt;</span> (cloud-&gt;points.size ());</div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;    point.r = 255;</div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;    point.g = 255;</div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160;    point.b = 255;</div>
<div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;    <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i_point = 0; i_point &lt; cloud-&gt;points.size (); i_point++)</div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;    {</div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;      point.x = cloud-&gt;points[i_point].x;</div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;      point.y = cloud-&gt;points[i_point].y;</div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160;      point.z = cloud-&gt;points[i_point].z;</div>
<div class="line"><a name="l00103"></a><span class="lineno">  103</span>&#160;      colored_cloud-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.push_back (point);</div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;    }</div>
<div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160;  }</div>
<div class="line"><a name="l00106"></a><span class="lineno">  106</span>&#160; </div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160;  point.r = 0;</div>
<div class="line"><a name="l00108"></a><span class="lineno">  108</span>&#160;  point.g = 0;</div>
<div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160;  point.b = 255;</div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i_vote = 0; i_vote &lt; <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.size (); i_vote++)</div>
<div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160;  {</div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;    point.x = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>[i_vote].x;</div>
<div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;    point.y = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>[i_vote].y;</div>
<div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;    point.z = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>[i_vote].z;</div>
<div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160;    colored_cloud-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.push_back (point);</div>
<div class="line"><a name="l00116"></a><span class="lineno">  116</span>&#160;  }</div>
<div class="line"><a name="l00117"></a><span class="lineno">  117</span>&#160;  colored_cloud-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#a4f34b45220c57f96607513ffad0d9582">height</a> += <span class="keyword">static_cast&lt;</span>uint32_t<span class="keyword">&gt;</span> (<a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>.size ());</div>
<div class="line"><a name="l00118"></a><span class="lineno">  118</span>&#160; </div>
<div class="line"><a name="l00119"></a><span class="lineno">  119</span>&#160;  <span class="keywordflow">return</span> (colored_cloud);</div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;}</div>
<div class="ttc" id="aclasspcl_1_1_point_cloud_html"><div class="ttname"><a href="classpcl_1_1_point_cloud.html">pcl::PointCloud&lt; pcl::PointXYZRGB &gt;</a></div></div>
<div class="ttc" id="aclasspcl_1_1_point_cloud_html_a2185a6453f8ad905d7bdf7b45754a160"><div class="ttname"><a href="classpcl_1_1_point_cloud.html#a2185a6453f8ad905d7bdf7b45754a160">pcl::PointCloud::width</a></div><div class="ttdeci">uint32_t width</div><div class="ttdoc">The point cloud width (if organized as an image-structure).</div><div class="ttdef"><b>Definition:</b> point_cloud.h:413</div></div>
<div class="ttc" id="aclasspcl_1_1_point_cloud_html_a4f34b45220c57f96607513ffad0d9582"><div class="ttname"><a href="classpcl_1_1_point_cloud.html#a4f34b45220c57f96607513ffad0d9582">pcl::PointCloud::height</a></div><div class="ttdeci">uint32_t height</div><div class="ttdoc">The point cloud height (if organized as an image-structure).</div><div class="ttdef"><b>Definition:</b> point_cloud.h:415</div></div>
<div class="ttc" id="astructpcl_1_1_point_x_y_z_r_g_b_html"><div class="ttname"><a href="structpcl_1_1_point_x_y_z_r_g_b.html">pcl::PointXYZRGB</a></div><div class="ttdoc">A point structure representing Euclidean xyz coordinates, and the RGB color.</div><div class="ttdef"><b>Definition:</b> point_types.hpp:607</div></div>
</div><!-- fragment -->
</div>
</div>
<a id="ac284edd6499950c3eafe533608e5b132"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac284edd6499950c3eafe533608e5b132">&#9670;&nbsp;</a></span>getDensityAtPoint()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename PointT &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">double <a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html">pcl::features::ISMVoteList</a>&lt; <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &gt;::getDensityAtPoint </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structpcl_1_1_point_x_y_z_r_g_b_a.html">PointT</a> &amp;&#160;</td>
          <td class="paramname"><em>point</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>sigma_dist</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns the density at the specified point. </p>
<dl class="params"><dt>参数</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">point</td><td>point of interest </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">sigma_dist</td><td></td></tr>
  </table>
  </dd>
</dl>
<div class="fragment"><div class="line"><a name="l00270"></a><span class="lineno">  270</span>&#160;{</div>
<div class="line"><a name="l00271"></a><span class="lineno">  271</span>&#160;  <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#ab49403392d4d4a0384c2a1c76d097b8b">validateTree</a> ();</div>
<div class="line"><a name="l00272"></a><span class="lineno">  272</span>&#160; </div>
<div class="line"><a name="l00273"></a><span class="lineno">  273</span>&#160;  <span class="keyword">const</span> <span class="keywordtype">size_t</span> n_vote_classes = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a5ffef33d1b4f225fbd38833d55c18cb1">votes_class_</a>.size ();</div>
<div class="line"><a name="l00274"></a><span class="lineno">  274</span>&#160;  <span class="keywordflow">if</span> (n_vote_classes == 0)</div>
<div class="line"><a name="l00275"></a><span class="lineno">  275</span>&#160;    <span class="keywordflow">return</span> (0.0);</div>
<div class="line"><a name="l00276"></a><span class="lineno">  276</span>&#160; </div>
<div class="line"><a name="l00277"></a><span class="lineno">  277</span>&#160;  <span class="keywordtype">double</span> sum_vote = 0.0;</div>
<div class="line"><a name="l00278"></a><span class="lineno">  278</span>&#160; </div>
<div class="line"><a name="l00279"></a><span class="lineno">  279</span>&#160;  <a class="code" href="structpcl_1_1_interest_point.html">pcl::InterestPoint</a> pt;</div>
<div class="line"><a name="l00280"></a><span class="lineno">  280</span>&#160;  pt.x = point.x;</div>
<div class="line"><a name="l00281"></a><span class="lineno">  281</span>&#160;  pt.y = point.y;</div>
<div class="line"><a name="l00282"></a><span class="lineno">  282</span>&#160;  pt.z = point.z;</div>
<div class="line"><a name="l00283"></a><span class="lineno">  283</span>&#160;  <span class="keywordtype">size_t</span> num_of_pts = <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a53a6809b8f7069b2f5a0a4f601f0059f">tree_</a>-&gt;<a class="code" href="classpcl_1_1_kd_tree_f_l_a_n_n.html#ab598d8e1220f1292b938e3a66f1ec370">radiusSearch</a> (pt, 3 * sigma_dist, <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a0ddbc7ee40f769a5c94f755197fefccb">k_ind_</a>, <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a3ddce2a6ca230560e4aa94d84816acb2">k_sqr_dist_</a>);</div>
<div class="line"><a name="l00284"></a><span class="lineno">  284</span>&#160; </div>
<div class="line"><a name="l00285"></a><span class="lineno">  285</span>&#160;  <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j &lt; num_of_pts; j++)</div>
<div class="line"><a name="l00286"></a><span class="lineno">  286</span>&#160;    sum_vote += <a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#aa5218ed40f67da06286a35f22cf9d9b3">votes_</a>-&gt;<a class="code" href="classpcl_1_1_point_cloud.html#af16a62638198313b9c093127c492c884">points</a>[<a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a0ddbc7ee40f769a5c94f755197fefccb">k_ind_</a>[j]].strength * exp (-<a class="code" href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a3ddce2a6ca230560e4aa94d84816acb2">k_sqr_dist_</a>[j] / (sigma_dist * sigma_dist));</div>
<div class="line"><a name="l00287"></a><span class="lineno">  287</span>&#160; </div>
<div class="line"><a name="l00288"></a><span class="lineno">  288</span>&#160;  <span class="keywordflow">return</span> (sum_vote);</div>
<div class="line"><a name="l00289"></a><span class="lineno">  289</span>&#160;}</div>
<div class="ttc" id="aclasspcl_1_1_kd_tree_f_l_a_n_n_html_ab598d8e1220f1292b938e3a66f1ec370"><div class="ttname"><a href="classpcl_1_1_kd_tree_f_l_a_n_n.html#ab598d8e1220f1292b938e3a66f1ec370">pcl::KdTreeFLANN::radiusSearch</a></div><div class="ttdeci">int radiusSearch(const PointT &amp;point, double radius, std::vector&lt; int &gt; &amp;k_indices, std::vector&lt; float &gt; &amp;k_sqr_distances, unsigned int max_nn=0) const</div><div class="ttdoc">Search for all the nearest neighbors of the query point in a given radius.</div><div class="ttdef"><b>Definition:</b> kdtree_flann.hpp:169</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_a0ddbc7ee40f769a5c94f755197fefccb"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a0ddbc7ee40f769a5c94f755197fefccb">pcl::features::ISMVoteList::k_ind_</a></div><div class="ttdeci">std::vector&lt; int &gt; k_ind_</div><div class="ttdoc">Stores neighbours indices.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:150</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_a3ddce2a6ca230560e4aa94d84816acb2"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a3ddce2a6ca230560e4aa94d84816acb2">pcl::features::ISMVoteList::k_sqr_dist_</a></div><div class="ttdeci">std::vector&lt; float &gt; k_sqr_dist_</div><div class="ttdoc">Stores square distances to the corresponding neighbours.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:153</div></div>
<div class="ttc" id="aclasspcl_1_1features_1_1_i_s_m_vote_list_html_a53a6809b8f7069b2f5a0a4f601f0059f"><div class="ttname"><a href="classpcl_1_1features_1_1_i_s_m_vote_list.html#a53a6809b8f7069b2f5a0a4f601f0059f">pcl::features::ISMVoteList::tree_</a></div><div class="ttdeci">pcl::KdTreeFLANN&lt; pcl::InterestPoint &gt;::Ptr tree_</div><div class="ttdoc">Stores the search tree.</div><div class="ttdef"><b>Definition:</b> implicit_shape_model.h:147</div></div>
<div class="ttc" id="astructpcl_1_1_interest_point_html"><div class="ttname"><a href="structpcl_1_1_interest_point.html">pcl::InterestPoint</a></div><div class="ttdoc">A point structure representing an interest point with Euclidean xyz coordinates, and an interest valu...</div><div class="ttdef"><b>Definition:</b> point_types.hpp:745</div></div>
</div><!-- fragment -->
</div>
</div>
<hr/>该类的文档由以下文件生成:<ul>
<li>recognition/include/pcl/recognition/<a class="el" href="implicit__shape__model_8h_source.html">implicit_shape_model.h</a></li>
<li>recognition/include/pcl/recognition/impl/<a class="el" href="implicit__shape__model_8hpp_source.html">implicit_shape_model.hpp</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><b>pcl</b></li><li class="navelem"><b>features</b></li><li class="navelem"><a class="el" href="classpcl_1_1features_1_1_i_s_m_vote_list.html">ISMVoteList</a></li>
    <li class="footer">制作者 <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1 </li>
  </ul>
</div>
</body>
</html>
